#include <iostream>
#include <algorithm>
using namespace std;
#define MAXN 100005
bool cmp(int x,int y){
	return x>y;
}
int a[MAXN];
bool out[MAXN];
int main()
{
	freopen("duel.in","r",stdin);
	freopen("duel.out","w",stdout);
	int n;
	cin>>n;
	for(int i=1;i<=n;i++) cin>>a[i];
	sort(a+1,a+n+1,cmp);
	int p=1;
	for(int i=1;i<=n;i++)
	{
		while(a[i]<=a[p]&&p<=n) p++;
		if(p>n) break;
		else
		{
			while(out[p]==true) p++;
			out[p]=true;
		}
	}
	int cnt=0;
	for(int i=1;i<=n;i++) if(out[i]==false) cnt++;
	cout<<cnt<<endl; 
	return 0;
}
